#ifndef SERIAL_H
#define SERIAL_H

/* prototypes */
void Serial_Init(void);

void Serial_SetMode(int Port, int Baud, int Bits, int Parity, int StopBits, int HardwareHandshake);

int Serial_SendChar(int Port, int Character);
int Serial_GetReadable(int Port);
int Serial_GetChar(int Port, int Timeout);

int Serial_Write(int Port, const char *Buffer, int Count, int Timeout);
int Serial_Read(int Port, char *Buffer, int Count, int Timeout);

int Serial_WaitSent(int Port, int Timeout);

#endif // SERIAL_H
